body {
    padding: 100px;
}

/*提示禁用状态*/
:disabled, [disabled], [aria-disabled="true"] {
    cursor: not-allowed;
}

/*隐藏鼠标光标*/
.hide-cursor {
    display: inline-block;
    width: 200px;
    height: 100px;
    background: deeppink;
    cursor: none;
}

/*透明边框扩大点击区域*/
.hit-area-border {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    color: white;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: skyblue;
    border: 10px solid transparent;
    background-clip: padding-box;
    cursor: pointer;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.3) inset, 0 0.1em 0.2em -0.05em rgba(0, 0, 0, 0.5);
}

/* 伪元素扩大点击区域 */
.hit-area {
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    position: relative;
    background: skyblue;
}

.hit-area::after {
    position: absolute;
    inset: -10px -10px -10px -10px;
    content: '';
    cursor: pointer;
}

/*用label替代checkbox*/
.checkboxes input[type="checkbox"] + label::before {
    content: '\a0';
    display: inline-block;
    vertical-align: 0.2em;
    width: 0.8em;
    height: 0.8em;
    margin-right: 0.2em;
    border-radius: 0.2em;
    background: silver;
    text-indent: 0.15em;
    line-height: 0.65;
}

.checkboxes input[type="checkbox"]:checked + label::before {
    content: '\2713';
    background: yellowgreen;
}

.checkboxes input[type="checkbox"] {
    position: absolute;
    clip: rect(0, 0, 0, 0);
}

.checkboxes input[type="checkbox"]:focus + label::before {
    box-shadow: 0 0 0.1em 0.1em #58a;
}

/*开关式按钮*/
.toggle-buttons input[type="checkbox"] {
    position: absolute;
    clip: rect(0, 0, 0, 0);
}

.toggle-buttons input[type="checkbox"] + label {
    display: inline-block;
    padding: 0.3em 0.5em;
    background: #ccc;
    background-image: linear-gradient(#ddd, #bbb);
    border: 1px solid rgba(0, 0, 0, 0.2);
    border-radius: 0.3em;
    box-shadow: 0 1px white inset;
    text-align: center;
    text-shadow: 0 1px 1px white;
}

.toggle-buttons input[type="checkbox"]:checked + label,
.toggle-buttons input[type="checkbox"]:active + label {
    box-shadow: 0.05em 0.1em 0.2em rgba(0, 0, 0, 0.6) inset;
    border-color: rgba(0, 0, 0, 0.3);
    background: #bbb;
}

/* 滚动提示 */
.scrolling-hints {
    height: 8em;
    width: 10em;
    padding: 0.3em 0.5em;
    border: 1px solid silver;
    overflow: auto;
    background: linear-gradient(white 30%, transparent), radial-gradient(at 50% 0, rgba(0, 0, 0, 0.2), transparent 70%);
    background-repeat: no-repeat;
    background-size: 100% 50px, 100% 15px;
    background-attachment: local, scroll;
}

/* 交互式的图片对比控件-resize方案 */
.image-slider {
    position: relative;
    display: inline-block;
}

.image-slider img {
    display: block;
    width: 200px;
    user-select: none;
}

.image-slider > img {
    filter: contrast(200%);
}

.image-slider > div {
    max-width: 100%;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 50%;
    overflow: hidden;
    resize: horizontal;
    z-index: 1;
}

.image-slider > div::before {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 12px;
    height: 12px;
    background: white;
    cursor: ew-resize;
    padding: 5px;
    background: linear-gradient(-45deg, white 50%, transparent 0);
    background-clip: content-box;
}

/*范围输入控件方案*/

.range-slider {
    position: relative;
    display: inline-block;
}

.range-slider img {
    width: 200px;
    display: block;
    user-select: none;
}

.range-slider > img {
    filter: contrast(200%);
}

.range-slider > div {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 50%;
    overflow: hidden;
    z-index: 1;
}

.range-slider input {
    position: absolute;
    left: 0;
    bottom: 10px;
    width: 100%;
    margin: 0;
    z-index: 1;
}

